package com.xxl.job.executor.my.mapper.rangland;

import com.xxl.job.executor.my.entity.BatchChgLogEntity;
import com.xxl.job.executor.my.entity.BatchInfoEntity;
import com.xxl.job.executor.my.entity.BatchStockEntity;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import java.util.Date;
import java.util.List;
import java.util.Map;

/**
 * <h3>xxl-job</h3>
 * <p>养猪系统数据查询</p>
 *
 * @author : 来朋
 * @date : 2020-12-19 16:26
 **/
@Mapper
@Repository
public interface RangeLandMapper {

    /**
     * 获取养猪系统的信息
     * @param iPage
     * @param iEachPageRow
     * @return
     */
    List<BatchStockEntity> getBatchStockList(@Param("pageIndex") Integer iPage,
                                             @Param("eachPageRows") Integer iEachPageRow,
                                             @Param("fdate") Date fDate);

    /**
     * 获取批次的存栏和日龄
     * @param strbatch
     * @param fdate
     * @return
     */
    List<Map<String,Object>> getBatchQtyAndDayolds(@Param("BatchNo") String strbatch, @Param("Times")Date fdate);

    /**
     * 获取批次的转群变动信息
     * @param strBatch
     * @param fDate
     * @return
     */
    List<BatchChgLogEntity> getBatchChgLogList(@Param("batchno") String strBatch, @Param("fdate") String fDate);

    BatchInfoEntity getBatchInfo(@Param("batchno") String strBatchNO);





}
